package com.edushare.common.vo;

import java.util.Date;

import com.edushare.common.vo.auto._UserPoll;

public class UserPoll extends _UserPoll implements DateComparision {
	public static final int POLL_PENDING 		= 10;
	public static final int POLL_COMPLETE 		= 20;
	
	public static final int ROLE_RESPONDENT   	= 10;
	public static final int ROLE_REVIEWER		= 20;
	
	public int compareTo(IDateComparable arg0) {
		if(getDate().getTime() < arg0.getDate().getTime())
			return -1;
		else if(arg0.getDate().getTime() == getDate().getTime())
			return 0;
		else
			return 1;
	}
	
	public Date getDate() {
		return getPoll().getPollEndDate();
	}
}
